# Cold driver

CFLAGS=@CFLAGS@ -I../include
LDFLAGS=@LDFLAGS@
LIBS=@LIBS@
CC=@CC@
RANLIB=@RANLIB@
LINT=@LINT@
YACC=@YACC@

SYS=@SYS@
CPU=@CPU@
VENDOR=@VENDOR@

prefix=@prefix@
BINDIR=$(prefix)/bin
SRCDIR=$(prefix)/src

VERSION=@VERSION@

OBJS = data.o buffer.o dict.o ident.o list.o object.o string.o \
       handled_frob.o quickhash.o

SRCS = `echo $(CDC_OBJS) $(COLDCORE_O) | sed -e 's/\.o/.c/g'`

#######
# rules

all: $(OBJS)

clean:
	rm -f *~ *.BAK *.bak

scrub:
	rm -f *.o *~ *.BAK *.bak

makefile:
	@cd $(prefix); configure -q

depend:
	@makedepend -- $(CFLAGS) -- $(SRCS) > /dev/null 2>&1
	@rm Makefile.bak

lint:
	$(LINT) -u $(SRCS)

patchable: scrub
	@chmod -f u+w Makefile
	@rm -f Makefile

include/parse.h:
	cd ../; make grammar.o include/parse.h
